<template>
  <div class="home">
    <button @click="getData">请求axios</button>
  </div>
</template>

<script>
// @ is an alias to /src
import HelloWorld from "@/components/HelloWorld.vue";
import axios from "axios";

export default {
  methods: {
    getData() {
      axios.get("/api/suggest?word=康志豪").then((res) => {
        console.log(res);
      });
    },
  },
};
</script>
